package fruit_machine

import pb "longmen/server/pkg/protobuf"

type FruitConfig struct {
	Idx            int     `json:"idx"`
	Name           string  `json:"name"`     //奖品名称
	Site           []int32 `json:"site"`     //位置
	MinOdds        int32   `json:"min_odds"` //最小倍数
	MaxOdds        int32   `json:"max_odds"` //最大倍数
	probability    float64
	CumProbability float64
	SamePrize      []int  //同奖id
	Icon           string //奖励区域图片
	BetId          int    //所属中奖区域id
}

type BetAreaConfig struct {
	BetId    int    `json:"bet_id"`
	Icon     string `json:"icon"`
	AwardIds []int  `json:"awardIds"` //对应的FruitConfig idx
}

type AwardTypeConfig struct {
	AwardTypeIdx AwardType
	Probability  float64
}

type FruitBetReq struct {
	UserId int64
}

type RewardResult struct {
	Idx  int   `json:"idx"`
	Site int32 `json:"site"`
}

type FruitGameHis struct {
	UserId        int64
	BetData       []*pb.FruitBetData //下注数据
	AwardType     AwardType
	AwardData     []*pb.FruitAwardData //奖励明细
	Ctime         int64
	AwardAmount   int
	BeforeBalance int
	AfterBalance  int
}
